import java.util.Scanner;
import java.util.Set;
import java.util.TreeSet;

/**
 * Created by JiaJia on 2019/3/27 0027.
 */
public class RandomNumber {
    public static void main(String[] args) {
        Scanner sc=new Scanner(System.in);
        while (sc.hasNext()){
            int number=sc.nextInt();
            Set<Integer> set=new TreeSet<>() ;

            while (number>=0){
                set.add(sc.nextInt());
                number--;
            }

            System.out.print(randomNumber(set));

        }
    }
    /*相当于去重+排序，用treeset就可以完成这个功能*/

    private static String randomNumber(Set<Integer> set){
        StringBuilder sb=new StringBuilder();
        for(Integer i:set){
            sb.append(i).append("\n");
        }

        return sb.toString();

    }

}